namespace TXLooker.WorkItemExtention.WIQL
{
    using System;
    using System.Globalization;
    using System.Reflection;

    public class NodeBoolConst : Node
    {
        private bool m_bool;

        public NodeBoolConst(bool b) : base(NodeType.BoolConst)
        {
            this.m_bool = b;
        }

        public override string ToString()
        {
            return this.m_bool.ToString(CultureInfo.InvariantCulture);
        }

        public override int Count
        {
            get
            {
                return 0;
            }
        }

        public override DataType DataType
        {
            get
            {
                return DataType.Bool;
            }
        }

        public override bool IsConst
        {
            get
            {
                return true;
            }
        }

        public override bool IsScalar
        {
            get
            {
                return false;
            }
        }

        public override Node this[int i]
        {
            get
            {
                return null;
            }
            set
            {
            }
        }

        public override Priority Priority
        {
            get
            {
                return Priority.Operand;
            }
        }

        public bool Value
        {
            get
            {
                return this.m_bool;
            }
            set
            {
                this.m_bool = value;
            }
        }
    }
}

